<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">
<title>业务详细</title>

<!-- <script src="1003/1003.js"></script> -->
<script type="text/javascript">
$(function(){
	$('.changeTime').hide();
	$('.changeShip').hide();
	
	$('#changetypecode').on('DOMNodeInserted',function(){
        var changetypecode = $(this).text();
		if(changetypecode == '01'){
			$('.changeTime').show();
			$('.changeShip').hide();
		}
		else if(changetypecode == '02'){
			$('.changeTime').hide();
			$('.changeShip').show();
		}
		else{
			$('.changeTime').hide();
			$('.changeShip').hide();
		}
    })	
})

function bindShipInfoList(data){
//	var str = "";
//	if(data.verifyresult >0)
//		str = '<img src="../img/jiaoyan1.png" alt="" style="width:20px;height:20px;" data-toggle="modal" data-target="#modalCheck" onclick="getVerify(\''+data.shipidnumber+'\')" title="点击查看详情">'; 
//	else if(data.verifyresult == 0)
//		str = '<img src="../img/jiaoyan2.png" alt="" style="width:20px;height:20px;" data-toggle="modal" data-target="#modalCheck" onclick="getVerify(\''+data.shipidnumber+'\')" title="点击查看详情">'; 
//	else if(data.verifyresult == -1)
//		str = '<img src="../img/jiaoyan3.png" alt="" style="width:20px;height:20px;" data-toggle="modal" data-target="#modalCheck" onclick="getVerify(\''+data.shipidnumber+'\')" title="点击查看详情">'; 
	
	var htmlStr = ''+		
				'<tr>'+
				'	<td>'+ data.shipidnumber +'</td>'+
				'	<td>'+ data.shipname +'</td>'+
//				'	<td>'+ data.technicalparameter +'</td>'+
				'</tr>';
	
	$('#TableShip').append(htmlStr);
}

var coordinateID = 'coordinate';
function bindCoordinateInfoList(data){
	var serialnumber = data.serialnumber;
	var latarea = data.latarea;
	var latdegree = data.latdegree;
	var latmin = data.latmin;
	var latsecond = data.latsecond;
	var lonarea = data.lonarea;
	var londegree = data.londegree;
	var lonmin = data.lonmin;
	var lonsecond = data.lonsecond;
	
	var htmlStr = ''+		
				'  <tbody class="coordinateForm">'+
				'  <tr>'+
				'    <td rowspan="2" style="vertical-align: middle;">'+
				'		'+ serialnumber +''+
				'	 </td>'+
				'    <td>   '+
				'	      <div class="form-group">'+
				'		    <label class="col-sm-4 control-label">经度</label>'+
				'		    <div class="col-sm-8">'+
				'				'+ latarea +''+
				'		    </div>'+
				'		  </div> '+
				'    </td>'+
				'    <td>'+ latdegree +'</td>'+
				'    <td>'+ latmin +'</td>'+
				'    <td>'+ latsecond +'</td>'+
				'  </tr>'+
				'  <tr>'+
				'    <td>'+
				'	      <div class="form-group">'+
				'		    <label class="col-sm-4 control-label">纬度</label>'+
				'		    <div class="col-sm-8">'+
				'				'+ lonarea +''+
				'		    </div>'+
				'		  </div> '+
				'	  </td>'+
				'    <td>'+ londegree +'</td>'+
				'    <td>'+ lonmin +'</td>'+
				'    <td>'+ lonsecond +'</td>'+
				'  </tr>'+
				'  </tbody>';
	
	$('#' + coordinateID).append(htmlStr);
}

function coordinateDelete(index){
	$('.tr_' + index).remove();
}

</script>
</head>
<body style="background-color: white;">
	<!-- 业务信息 -->
	<table class="table table-bordered">
	<tbody>
		<tr>
			<td class="tdTitle ">
				 原申请单编号：
			</td>
			<td>
				<span id="oldapplyno"></span>
			</td>
			<td class="tdTitle ">
				  变更类型：
			</td>
			<td colspan="3">
				<span id="changetype"></span>
				<span id="changetypecode" style="display: none"></span>
			</td>
		</tr>
	    <tr class="changeTime">
			<td class="tdTitle">
				申请延期期限：
			</td>
			<td colspan="5">
				<span id="delaydate"></span>
			</td>
		</tr> 
		<tr class="changeTime">
			<td class="tdTitle">
				计划开工日期：
			</td>
			<td class="tdContent">
				<span id="workbegintime"></span>
			</td>
			<td class="tdTitle">
				预计完工日期：
			</td>
			<td class="tdContent">
				<span id="workendtime"></span>
			</td>
			<td class="tdTitle">
				预计完工天数：
			</td>
			<td class="tdContent">
				<span id="days"></span>
			</td>
		</tr>
	</tbody>
	</table>
	
    <table class="table table-bordered changeShip" id="TableShip" style="text-align: center;">
   	<thead>
	   	<tr>
			<th style="text-align: center; background-color: #eee; width: 120px;">船舶识别号</th>
			<th style="text-align: center; background-color: #eee; width: 200px;">中文船舶名称</th>
			<!-- <th style="text-align: center; background-color: #eee;">主要技术参数</th> -->
			<!-- <th style="text-align: center; background-color: #eee;">校验</th> -->
	    </tr>
    </thead>
	<tbody>

	</tbody>
	</table>
	
	  <div class="modal fade" id="modalCheck" tabindex="-1" role="dialog"
		aria-labelledby="myModalLabel" aria-hidden="true">
		<div class="modal-dialog">
			<div class="modal-content" style="width: 800px; height: 600px; overflow:auto;">
			  <div class="modal-header">
					<button type="button" class="close" data-dismiss="modal"
						aria-hidden="true">&times;</button>
					<h4 class="modal-title" id="myModalLabel">校验信息</h4>
				</div>
				
				<div class="modal-body" id="checkinfo">
					<table class="table" id="certShip">
						<caption>法定证书校验</caption>
						<thead>
							<tr>
								<th style="text-align: center;width:35%">校验内容</th>
								<th style="text-align: center;width:10%">校验结果</th>
								<th style="text-align: center;width:55%">结果详情</th>
							</tr>
						</thead>
						</tbody>
					</table>
					
					<table class="table" id="fsc">
						<caption>船舶安检信息校验</caption>
						<thead>
							<tr>
								<th style="text-align: center;width:35%">校验内容</th>
								<th style="text-align: center;width:10%">校验结果</th>
								<th style="text-align: center;width:55%">结果详情</th>
							</tr>
						</thead>
						</tbody>
					</table>
				</div>
			</div>
			<!-- /.modal-content -->
		</div>
		<!-- /.modal -->
	</div>
</body>
</html>